<template>
  <!-- 搜索历史 -->
  <div class="searchli-continer">
    <van-cell title="搜索历史" @click="delLiAll" value="全部删除"></van-cell>

    <van-cell :title="item" v-for="(item, index) in lishiList" :key="index">
      <van-icon name="cross" slot="right-icon" @click="delLi(item)" />
    </van-cell>
  </div>
</template>

<script>
export default {
  data() {
    return {};
  },
  props: ["lishiList"],
  methods: {
    //点击删除
    delLi(val) {
      this.$emit("delLi", val);
    },
    //全部删除
    delLiAll() {
      this.$emit("delLiAll");
    },
  },
};
</script>

<style>
</style>